package com.lx.timer.springtask;

import org.quartz.JobExecutionContext;
import org.quartz.JobExecutionException;
import org.springframework.scheduling.quartz.QuartzJobBean;

/**
 * 整合Quartz
 *
 * @author 段誉
 * @create 2019-04-02 14:42
 */
public class TestQuartz extends QuartzJobBean {

  /**
   * 执行定时任务
   * @param jobExecutionContext
   * @throws JobExecutionException
   */
  @Override
  protected void executeInternal(JobExecutionContext jobExecutionContext) throws JobExecutionException {
    System.out.println("quartz task" + System.currentTimeMillis());
  }
}
